<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.11"/>
<title>eRPC API Reference: erpc::MessageBuffer Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { init_search(); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="customdoxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="nxp_logo_small.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">eRPC API Reference
   &#160;<span id="projectnumber">Rev. 1.7.4</span>
   </div>
   <div id="projectbrief">NXP Semiconductors</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.11 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="modules.html"><span>API&#160;Reference</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="inherits.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('classerpc_1_1_message_buffer.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#nested-classes">Classes</a> &#124;
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="classerpc_1_1_message_buffer-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">erpc::MessageBuffer Class Reference<div class="ingroups"><a class="el" href="group__infra.html">Infrastructure</a> &raquo; <a class="el" href="group__infra__codec.html">Serialization</a></div></div>  </div>
</div><!--header-->
<div class="contents">

<p>Represents a memory buffer containing a message.  
 <a href="classerpc_1_1_message_buffer.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="erpc__message__buffer_8h_source.html">erpc_message_buffer.h</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="nested-classes"></a>
Classes</h2></td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">class &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer_1_1_cursor.html">Cursor</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight"><a class="el" href="classerpc_1_1_message_buffer_1_1_cursor.html" title="Cursor within a MessageBuffer. ">Cursor</a> within a <a class="el" href="classerpc_1_1_message_buffer.html" title="Represents a memory buffer containing a message. ">MessageBuffer</a>.  <a href="classerpc_1_1_message_buffer_1_1_cursor.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:ada32e828c2edcd3546376d4d3ee90081"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#ada32e828c2edcd3546376d4d3ee90081">MessageBuffer</a> (void)</td></tr>
<tr class="memdesc:ada32e828c2edcd3546376d4d3ee90081"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructor.  <a href="#ada32e828c2edcd3546376d4d3ee90081">More...</a><br /></td></tr>
<tr class="separator:ada32e828c2edcd3546376d4d3ee90081"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7785b972a2ed8719a7afcd8f15c1b3ca"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#a7785b972a2ed8719a7afcd8f15c1b3ca">MessageBuffer</a> (uint8_t *buffer, uint16_t length)</td></tr>
<tr class="memdesc:a7785b972a2ed8719a7afcd8f15c1b3ca"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructor.  <a href="#a7785b972a2ed8719a7afcd8f15c1b3ca">More...</a><br /></td></tr>
<tr class="separator:a7785b972a2ed8719a7afcd8f15c1b3ca"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae68c8d9c1ded075f6a85ecd92fb958be"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#ae68c8d9c1ded075f6a85ecd92fb958be">set</a> (uint8_t *buffer, uint16_t length)</td></tr>
<tr class="memdesc:ae68c8d9c1ded075f6a85ecd92fb958be"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function set new buffer and his length.  <a href="#ae68c8d9c1ded075f6a85ecd92fb958be">More...</a><br /></td></tr>
<tr class="separator:ae68c8d9c1ded075f6a85ecd92fb958be"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adb0539e7fbd649e0902efb61b7b7cf6b"><td class="memItemLeft" align="right" valign="top">uint8_t *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#adb0539e7fbd649e0902efb61b7b7cf6b">get</a> (void)</td></tr>
<tr class="memdesc:adb0539e7fbd649e0902efb61b7b7cf6b"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function returns pointer to buffer to read/write.  <a href="#adb0539e7fbd649e0902efb61b7b7cf6b">More...</a><br /></td></tr>
<tr class="separator:adb0539e7fbd649e0902efb61b7b7cf6b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aab101146fdec5df33e7bdf7608dddcef"><td class="memItemLeft" align="right" valign="top">const uint8_t *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#aab101146fdec5df33e7bdf7608dddcef">get</a> (void) const </td></tr>
<tr class="memdesc:aab101146fdec5df33e7bdf7608dddcef"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function returns pointer to buffer to read/write.  <a href="#aab101146fdec5df33e7bdf7608dddcef">More...</a><br /></td></tr>
<tr class="separator:aab101146fdec5df33e7bdf7608dddcef"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a064fda9eef763265dd9de81142011e33"><td class="memItemLeft" align="right" valign="top">uint16_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#a064fda9eef763265dd9de81142011e33">getLength</a> (void) const </td></tr>
<tr class="memdesc:a064fda9eef763265dd9de81142011e33"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function returns length of buffer.  <a href="#a064fda9eef763265dd9de81142011e33">More...</a><br /></td></tr>
<tr class="separator:a064fda9eef763265dd9de81142011e33"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa0aa4b6ee452d083cbaaf0ce5fe6517f"><td class="memItemLeft" align="right" valign="top">uint16_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#aa0aa4b6ee452d083cbaaf0ce5fe6517f">getUsed</a> (void) const </td></tr>
<tr class="memdesc:aa0aa4b6ee452d083cbaaf0ce5fe6517f"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function returns length of used space of buffer.  <a href="#aa0aa4b6ee452d083cbaaf0ce5fe6517f">More...</a><br /></td></tr>
<tr class="separator:aa0aa4b6ee452d083cbaaf0ce5fe6517f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7432d37f64b91d65a8df06016cec22e1"><td class="memItemLeft" align="right" valign="top">uint16_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#a7432d37f64b91d65a8df06016cec22e1">getFree</a> (void) const </td></tr>
<tr class="memdesc:a7432d37f64b91d65a8df06016cec22e1"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function returns length of free space of buffer.  <a href="#a7432d37f64b91d65a8df06016cec22e1">More...</a><br /></td></tr>
<tr class="separator:a7432d37f64b91d65a8df06016cec22e1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa0170a6e243e15fc7271d792624b3e96"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#aa0170a6e243e15fc7271d792624b3e96">setUsed</a> (uint16_t used)</td></tr>
<tr class="memdesc:aa0170a6e243e15fc7271d792624b3e96"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function sets length of used space of buffer.  <a href="#aa0170a6e243e15fc7271d792624b3e96">More...</a><br /></td></tr>
<tr class="separator:aa0170a6e243e15fc7271d792624b3e96"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a046c0aa6baf607d5de23f18cfa13f08e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__infra.html#ga5f8872e58f09a16d192bf664f9898651">erpc_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#a046c0aa6baf607d5de23f18cfa13f08e">read</a> (uint16_t offset, void *data, uint32_t length)</td></tr>
<tr class="memdesc:a046c0aa6baf607d5de23f18cfa13f08e"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function read data from local buffer.  <a href="#a046c0aa6baf607d5de23f18cfa13f08e">More...</a><br /></td></tr>
<tr class="separator:a046c0aa6baf607d5de23f18cfa13f08e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9f47a5776a51c53d4a8516c354d21d19"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__infra.html#ga5f8872e58f09a16d192bf664f9898651">erpc_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#a9f47a5776a51c53d4a8516c354d21d19">write</a> (uint16_t offset, const void *data, uint32_t length)</td></tr>
<tr class="memdesc:a9f47a5776a51c53d4a8516c354d21d19"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function write data to local buffer.  <a href="#a9f47a5776a51c53d4a8516c354d21d19">More...</a><br /></td></tr>
<tr class="separator:a9f47a5776a51c53d4a8516c354d21d19"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad37d276294bd8d587a741ce0cee14967"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__infra.html#ga5f8872e58f09a16d192bf664f9898651">erpc_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#ad37d276294bd8d587a741ce0cee14967">copy</a> (const <a class="el" href="classerpc_1_1_message_buffer.html">MessageBuffer</a> *other)</td></tr>
<tr class="memdesc:ad37d276294bd8d587a741ce0cee14967"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function copy given message buffer to local instance.  <a href="#ad37d276294bd8d587a741ce0cee14967">More...</a><br /></td></tr>
<tr class="separator:ad37d276294bd8d587a741ce0cee14967"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a673ecf17b4876dcf4dff6313c5375d8c"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#a673ecf17b4876dcf4dff6313c5375d8c">swap</a> (<a class="el" href="classerpc_1_1_message_buffer.html">MessageBuffer</a> *other)</td></tr>
<tr class="memdesc:a673ecf17b4876dcf4dff6313c5375d8c"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function swap message buffer attributes between given instance and local instance.  <a href="#a673ecf17b4876dcf4dff6313c5375d8c">More...</a><br /></td></tr>
<tr class="separator:a673ecf17b4876dcf4dff6313c5375d8c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac846f6d4c3acba8c49995d4d338b11e9"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ac846f6d4c3acba8c49995d4d338b11e9"></a>
&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#ac846f6d4c3acba8c49995d4d338b11e9">operator uint8_t *</a> (void)</td></tr>
<tr class="memdesc:ac846f6d4c3acba8c49995d4d338b11e9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Casting operator return local buffer. <br /></td></tr>
<tr class="separator:ac846f6d4c3acba8c49995d4d338b11e9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a553560547fa1b61a113a81279b80d043"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a553560547fa1b61a113a81279b80d043"></a>
&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#a553560547fa1b61a113a81279b80d043">operator const uint8_t *</a> (void) const </td></tr>
<tr class="memdesc:a553560547fa1b61a113a81279b80d043"><td class="mdescLeft">&#160;</td><td class="mdescRight">Casting operator return local buffer. <br /></td></tr>
<tr class="separator:a553560547fa1b61a113a81279b80d043"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aedf09a86aef402ba74387c8590bcf23c"><td class="memItemLeft" align="right" valign="top">uint8_t &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#aedf09a86aef402ba74387c8590bcf23c">operator[]</a> (int index)</td></tr>
<tr class="memdesc:aedf09a86aef402ba74387c8590bcf23c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Array operator return value of buffer at given index.  <a href="#aedf09a86aef402ba74387c8590bcf23c">More...</a><br /></td></tr>
<tr class="separator:aedf09a86aef402ba74387c8590bcf23c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2f3450dcebc3fec37f2d5719847042f8"><td class="memItemLeft" align="right" valign="top">const uint8_t &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_message_buffer.html#a2f3450dcebc3fec37f2d5719847042f8">operator[]</a> (int index) const </td></tr>
<tr class="memdesc:a2f3450dcebc3fec37f2d5719847042f8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Array operator return value of buffer at given index.  <a href="#a2f3450dcebc3fec37f2d5719847042f8">More...</a><br /></td></tr>
<tr class="separator:a2f3450dcebc3fec37f2d5719847042f8"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Represents a memory buffer containing a message. </p>
<p>The <a class="el" href="classerpc_1_1_message_buffer.html" title="Represents a memory buffer containing a message. ">MessageBuffer</a> object does not own the buffer memory. It simply provides an interface to accessing that memory in a convenient manner. </p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="ada32e828c2edcd3546376d4d3ee90081"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">erpc::MessageBuffer::MessageBuffer </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Constructor. </p>
<p>This function initializes object attributes. </p>

</div>
</div>
<a class="anchor" id="a7785b972a2ed8719a7afcd8f15c1b3ca"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">erpc::MessageBuffer::MessageBuffer </td>
          <td>(</td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>buffer</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint16_t&#160;</td>
          <td class="paramname"><em>length</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Constructor. </p>
<p>This function initializes object attributes.</p>
<p>param[in] buffer Pointer to buffer. param[in] length Length of buffer. </p>

</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="ae68c8d9c1ded075f6a85ecd92fb958be"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void erpc::MessageBuffer::set </td>
          <td>(</td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>buffer</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint16_t&#160;</td>
          <td class="paramname"><em>length</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>This function set new buffer and his length. </p>
<p>This function set buffer to read/write data.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">buffer</td><td>Pointer to another buffer to read/write data. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">length</td><td>Length of buffer. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="adb0539e7fbd649e0902efb61b7b7cf6b"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">uint8_t* erpc::MessageBuffer::get </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>This function returns pointer to buffer to read/write. </p>
<dl class="section return"><dt>Returns</dt><dd>Pointer to buffer to read/write. </dd></dl>

</div>
</div>
<a class="anchor" id="aab101146fdec5df33e7bdf7608dddcef"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">const uint8_t* erpc::MessageBuffer::get </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>This function returns pointer to buffer to read/write. </p>
<dl class="section return"><dt>Returns</dt><dd>Pointer to buffer to read/write. </dd></dl>

</div>
</div>
<a class="anchor" id="a064fda9eef763265dd9de81142011e33"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">uint16_t erpc::MessageBuffer::getLength </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>This function returns length of buffer. </p>
<dl class="section return"><dt>Returns</dt><dd>Length of buffer. </dd></dl>

</div>
</div>
<a class="anchor" id="aa0aa4b6ee452d083cbaaf0ce5fe6517f"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">uint16_t erpc::MessageBuffer::getUsed </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>This function returns length of used space of buffer. </p>
<dl class="section return"><dt>Returns</dt><dd>Length of used space of buffer. </dd></dl>

</div>
</div>
<a class="anchor" id="a7432d37f64b91d65a8df06016cec22e1"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">uint16_t erpc::MessageBuffer::getFree </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>This function returns length of free space of buffer. </p>
<dl class="section return"><dt>Returns</dt><dd>Length of free space of buffer. </dd></dl>

</div>
</div>
<a class="anchor" id="aa0170a6e243e15fc7271d792624b3e96"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void erpc::MessageBuffer::setUsed </td>
          <td>(</td>
          <td class="paramtype">uint16_t&#160;</td>
          <td class="paramname"><em>used</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>This function sets length of used space of buffer. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">used</td><td>Length of used space of buffer. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a046c0aa6baf607d5de23f18cfa13f08e"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__infra.html#ga5f8872e58f09a16d192bf664f9898651">erpc_status_t</a> MessageBuffer::read </td>
          <td>(</td>
          <td class="paramtype">uint16_t&#160;</td>
          <td class="paramname"><em>offset</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>data</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>length</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function read data from local buffer. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">offset</td><td>Offset in local buffer. </td></tr>
    <tr><td class="paramdir">[in,out]</td><td class="paramname">data</td><td>Given buffer to save read data. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">length</td><td>Length of data to read.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Status from reading data. </dd></dl>

</div>
</div>
<a class="anchor" id="a9f47a5776a51c53d4a8516c354d21d19"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__infra.html#ga5f8872e58f09a16d192bf664f9898651">erpc_status_t</a> MessageBuffer::write </td>
          <td>(</td>
          <td class="paramtype">uint16_t&#160;</td>
          <td class="paramname"><em>offset</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const void *&#160;</td>
          <td class="paramname"><em>data</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>length</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function write data to local buffer. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">offset</td><td>Offset in local buffer. </td></tr>
    <tr><td class="paramdir">[in,out]</td><td class="paramname">data</td><td>Given buffer from which are copied data. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">length</td><td>Length of data to write.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Status from reading data. </dd></dl>

</div>
</div>
<a class="anchor" id="ad37d276294bd8d587a741ce0cee14967"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__infra.html#ga5f8872e58f09a16d192bf664f9898651">erpc_status_t</a> MessageBuffer::copy </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classerpc_1_1_message_buffer.html">MessageBuffer</a> *&#160;</td>
          <td class="paramname"><em>other</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function copy given message buffer to local instance. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">other</td><td>MesageBuffer to copy.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Status from reading data. </dd></dl>

</div>
</div>
<a class="anchor" id="a673ecf17b4876dcf4dff6313c5375d8c"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void MessageBuffer::swap </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classerpc_1_1_message_buffer.html">MessageBuffer</a> *&#160;</td>
          <td class="paramname"><em>other</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function swap message buffer attributes between given instance and local instance. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">other</td><td>MesageBuffer to swap. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="aedf09a86aef402ba74387c8590bcf23c"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">uint8_t&amp; erpc::MessageBuffer::operator[] </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>index</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Array operator return value of buffer at given index. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">index</td><td>Index in buffer. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a2f3450dcebc3fec37f2d5719847042f8"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">const uint8_t&amp; erpc::MessageBuffer::operator[] </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>index</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Array operator return value of buffer at given index. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">index</td><td>Index in buffer. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li><a class="el" href="erpc__message__buffer_8h_source.html">erpc_message_buffer.h</a></li>
<li>erpc_message_buffer.cpp</li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- HTML footer for doxygen 1.8.5-->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul class="foot">
    <li class="footer">Copyright 2016-2020 NXP Semiconductors. All rights reserved.
    </li>
  </ul>
</div>
</body>
</html>
